import datetime

TZ_DELTA = datetime.timedelta(hours=8)

def local_now():
    utc = datetime.datetime.utcnow()
    return utc + TZ_DELTA

def local_time(dt):
    dt += TZ_DELTA
    return dt

def utc_time(dt):
    dt -= TZ_DELTA
    return dt

